package com.zzh.bc.model;

import com.zzh.bc.annotations.HColumn;

/**
 * 接口参数表
 */
public class ApiParamModel {
    //表名称
    public static final String TABLE_NAME = "zh_apis_params";
    /**
     * 列明
     */
    public static final String SQL_COLUMN_NAME = "api_param_id, api_param_name,api_req_method_id,api_param_key,api_param_value,api_project_id,api_params_details,created_by,created_time,updated_by,updated_time";

    public static final String SQL_UPDATE_COLUMN_NAME = "UPDATE " + TABLE_NAME +
            " SET api_param_name=?,api_req_method_id=?,api_param_key=?,api_param_value=?,api_project_id=?,api_params_details=?,created_by=?,created_time=?,updated_by=?,updated_time=? WHERE api_param_id=?";

    public static final String SQL_DELETE = "DELETE FROM " + TABLE_NAME + " WHERE api_project_id=?";
    /**
     * 列明占位符
     */
    public static final String SQL_COLUMN_PARAMS = "?,?,?,?,?,?,?,?,?,?,?";
    @HColumn(columnName = "api_param_id")
    private String apiParamId;
    @HColumn(columnName = "api_param_name")
    private String apiParamName;
    @HColumn(columnName = "api_req_method_id")
    private String apiReqMethodId;
    @HColumn(columnName = "api_param_key")
    private String apiParamKey;
    @HColumn(columnName = "api_param_value")
    private String apiParamValue;
    /**
     * 属于哪个接口
     */
    @HColumn(columnName = "api_project_id")
    private String apiProjectId;
    @HColumn(columnName = "created_by")
    private String createdBy;
    @HColumn(columnName = "created_time")
    private long createdTime;
    @HColumn(columnName = "updated_by")
    private String updatedBy;
    @HColumn(columnName = "updated_time")
    private long updatedTime;
    @HColumn(columnName = "api_params_details")
    private String apiParamsDetails;

    public String getApiParamId() {
        return apiParamId == null ? "" : apiParamId;
    }

    public void setApiParamId(String apiParamId) {
        this.apiParamId = apiParamId;
    }

    public String getApiParamName() {
        return apiParamName == null ? "" : apiParamName;
    }

    public void setApiParamName(String apiParamName) {
        this.apiParamName = apiParamName;
    }

    public String getApiReqMethodId() {
        return apiReqMethodId == null ? "" : apiReqMethodId;
    }

    public void setApiReqMethodId(String apiReqMethodId) {
        this.apiReqMethodId = apiReqMethodId;
    }

    public String getApiParamKey() {
        return apiParamKey == null ? "" : apiParamKey;
    }

    public void setApiParamKey(String apiParamKey) {
        this.apiParamKey = apiParamKey;
    }

    public String getApiParamValue() {
        return apiParamValue == null ? "" : apiParamValue;
    }

    public void setApiParamValue(String apiParamValue) {
        this.apiParamValue = apiParamValue;
    }

    public String getApiProjectId() {
        return apiProjectId == null ? "" : apiProjectId;
    }

    public void setApiProjectId(String apiProjectId) {
        this.apiProjectId = apiProjectId;
    }

    public String getCreatedBy() {
        return createdBy == null ? "" : createdBy;
    }

    public void setCreatedBy(String createdBy) {
        this.createdBy = createdBy;
    }

    public long getCreatedTime() {
        return createdTime;
    }

    public void setCreatedTime(long createdTime) {
        this.createdTime = createdTime;
    }

    public String getUpdatedBy() {
        return updatedBy == null ? "" : updatedBy;
    }

    public void setUpdatedBy(String updatedBy) {
        this.updatedBy = updatedBy;
    }

    public long getUpdatedTime() {
        return updatedTime;
    }

    public void setUpdatedTime(long updatedTime) {
        this.updatedTime = updatedTime;
    }

    public String getApiParamsDetails() {
        return apiParamsDetails == null ? "" : apiParamsDetails;
    }

    public void setApiParamsDetails(String apiParamsDetails) {
        this.apiParamsDetails = apiParamsDetails;
    }
}
